projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0055362
)
* lisp/emacs-lisp/bindat.el (sint): Burp in dynbind (bug#69749)
author
Stefan Monnier
<monnier@iro.umontreal.ca>
Fri, 15 Mar 2024 16:45:09 +0000
(12:45 -0400)
committer
Stefan Monnier
<monnier@iro.umontreal.ca>
Fri, 15 Mar 2024 16:45:09 +0000
(12:45 -0400)
lisp/emacs-lisp/bindat.el
patch
|
blob
|
history
diff --git
a/lisp/emacs-lisp/bindat.el
b/lisp/emacs-lisp/bindat.el
index ef0ec688dbd14616ea171827e777a79241493328..42ba89ba2c19fdf956b8b237cfc7d41dc4fd5bce 100644
(file)
--- a/
lisp/emacs-lisp/bindat.el
+++ b/
lisp/emacs-lisp/bindat.el
@@
-944,9
+944,13
@@
a bindat type expression."
(bindat-defmacro sint (bitlen le)
"Signed integer of size BITLEN.
Big-endian if LE is nil and little-endian if not."
+ (unless lexical-binding
+ (error "The `sint' type requires 'lexical-binding'"))
(let ((bl (make-symbol "bitlen"))
(max (make-symbol "max"))
(wrap (make-symbol "wrap")))
+ ;; FIXME: This `let*' around the `struct' results in code which the
+ ;; byte-compiler does not handle efficiently. 🙁
`(let* ((,bl ,bitlen)
(,max (ash 1 (1- ,bl)))
(,wrap (+ ,max ,max)))